package com.jml.泛型;

import java.util.concurrent.atomic.AtomicInteger;
import java.util.function.Consumer;

public class DemoFanXing<T, K, V> {
    public static void main(String[] args) {
        AtomicInteger x = new AtomicInteger();
        int y = 0;
        foo((Integer a) -> {
            x.set(a + y);
        });
    }

    public static void foo(Consumer<Integer> a) {
        a.accept(1);
    }
}
